﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using TimeTableManagement.Models;

namespace TimeTableManagement.Controllers
{
    
    public class HomeController : Controller
    {
         
        QLSVContext _context = new QLSVContext();
        //
        // GET: /Home/

        public ActionResult Index()
        {
            var model = _context.Tb_News.Where(g => g.type==6);
            return View(model);
        }
         
        public ActionResult News(decimal id)
        {
           var model = _context.Tb_News.Find(id);
           return View(model);
        }
        public ViewResult Error()
        {
            return View();
        }
    }
}
